package com.mikepenz.app.activity.card;

import android.os.Bundle;
import android.widget.ListView;

import com.mikepenz.app.R;
import com.mikepenz.app.adapter.PayDetailAdapter;
import com.mikepenz.bean.PayOrderBean;
import com.quickdv.activity.BaseActivity;

import java.util.ArrayList;
import java.util.List;

import butterknife.InjectView;

public class PayDetailListActivity extends BaseActivity {

    List<PayOrderBean> data;
    PayDetailAdapter adapter;
    @InjectView(R.id.paydetail_list)
    ListView paydetailList;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
    }


    @Override
    public int getLayoutID() {
        return R.layout.activity_pay_detail_list;
    }

    @Override
    public void initView() {
        paydetailList.setAdapter(adapter);
    }

    @Override
    public void initActionbar() {

    }

    @Override
    public void initData() {
        data = new ArrayList<>();

        for (int i = 0; i < 10; i++) {
            PayOrderBean order = new PayOrderBean();
            if (i % 3 == 0) {
                order.setType("1");
            } else
                order.setType("0");

            data.add(order);

        }
        adapter = new PayDetailAdapter(this, data);
    }
}
